package com.hz.house.bean.es.building;

import lombok.Data;
import org.springframework.data.annotation.Id;
import org.springframework.data.elasticsearch.annotations.Document;
import org.springframework.data.elasticsearch.annotations.Field;
import org.springframework.data.elasticsearch.annotations.FieldType;

import java.util.List;

/**
 * <p> 楼盘检索文档.
 * <p> 文档的索引和type均由常量定义
 * @author lfw
 */
@Data
@Document(indexName = "house_purchase_helper_building",type = "house")
public class BuildingSearchDocumentBean {
	
	//__________以下是基本信息_____________
	
	//es 文档唯一id，也是楼盘id
	@Id
	private Integer id;
	
	@Field(type = FieldType.Text)
	private String name;//楼盘名字
	
	@Field(type = FieldType.Integer)
	private Integer brandId;//楼盘品牌公司的id
	
	@Field(type = FieldType.Integer)
	private Integer regionId;//区域id
	
	@Field(type =FieldType.Text)
	private String regionName;//区域名称
	
	@Field(type = FieldType.Integer)
	private Integer visits;//访问量
	
	@Field(type =FieldType.Integer)
	private Integer comments;//评论量
	
	@Field(type = FieldType.Integer)
	private Integer sellStatus;//售卖状态
	
	@Field(type = FieldType.Integer)
	private Integer rank;//排名
	
	@Field(type = FieldType.Integer)
	private Integer isHot;//是否是热门楼盘
	
	@Field(type = FieldType.Text)
	private String planKaiPan;//预计开盘时间
	
	@Field(type = FieldType.Text)
	private String coverImg;//楼盘封面
	
	@Field(type = FieldType.Text)
	private String showPrice;//展示价格

	@Field(type = FieldType.Integer)
	private Integer suplusHose;//剩余房源套数
	
	@Field(type = FieldType.Text)
	private List<String> houseModel;//户型图
	
	
	
	//____________以下是开盘信息_______________
	
	@Field(type = FieldType.Nested)
	private List<KaiPanSearchBean> kps;//包括价格和面积信息
	
	//____________以下是周边信息______________
	
	/*@Field(type = FieldType.Nested)
	private List<ZhouBianSearchBean> zbs;//周边信息，地铁和商场*/
	
	//____________以下是标签信息_______________
	
	@Field(type = FieldType.Nested)
	private List<TagSearchBean> tags;
	
	//_____________以下是置顶信息________________
	
	/*@Field(type = FieldType.Nested)
	private List<TopSearchBean> tops;*/
}
